1. Field of the invention
The present invention is related to a method and apparatus for the synchronization shift between an original image and a reproduced image of video signal, and particularly to a method and apparatus for accurately detecting the synchronization shift between an original image and a reproduced image of video signal outputted from a video codec or the like in a system for evaluating the video codec.
2. Description of the Related Art
As an example of the conventional method and apparatus for synchronizing an original image with a reproduced image of video signal, there is a method invented by the present inventors and described in Published Unexamined Patent Application No. 8-205156 (U.S. Pat. No. 5,574,500), etc. This method is outlined with reference to FIG. 10.
When an original image is inputted from an image source 51 to a first input unit 52, the first input unit 52 performs an A/D conversion of this image, and then outputs it to a synchronization marker adding unit 53. The synchronization marker adding unit 53 adds a synchronization maker, for instance, of a rectangular wave to incoming digital data. The digital data to which the synchronization marker has been added is sent to a system to be evaluated 57 via an output unit 56.
The system to be evaluated 57 is a digital television codec which is a subject to be tested, and the system to be evaluated 57 codes incoming digital data, and thereafter decodes and outputs it to a second input unit 58. The second input unit 58 digitizes the decoded data and outputs it. The reproduced image data outputted from the second input unit 58 is inputted to a synchronization control unit 54. The synchronization control unit 54 controls the delay by a delay unit 55 so that the marker of the original data delayed at the delay unit 55 matches that of the reproduced image data. The delay is, for instance, one frame or several frames. Consequently, the original image data can be synchronized with the reproduced image data.
However, in the above described prior art, a rectangular wave was used as a waveform for the synchronization marker. A rectangular wave contains many frequencies, and if noises of various frequencies are superposed on the rectangular wave by video codec or the like, the waveform of the rectangular wave collapses. It is substantially impossible to remove the noises to restore the waveform: of the marker to the rectangular wave. Accordingly, the synchronization must be performed by detecting the synchronization shift by the collapsed marker waveform, and a synchronization shift cannot be accurately detected, which leads to a problem that an accurate synchronization is not provided.
It is the object of the present invention to remove the above described prior art problem and provide a method and apparatus for the detecting a synchronization shift, in which the synchronization shift between an original image and a reproduced image of video signal can be accurately detected even if a noise is generated by a video codec or the like.
To accomplish the above object, the present invention is a method for detecting the synchronization shift between an original image and a reproduced image of video signal, characterized in that a signal of a substantially single frequency is used as the synchronization marker for the original image and the processed image, and the signal is overwritten on-a plurality of predetermined lines of the original image.
Further, the present invention is characterized by subjecting the reproduced image to a narrow-band band-pass filtering to extract the signal-frequency signal, and calculating the inner product of a signal obtained by subjecting the signal-frequency signal to an offset processing and the signal-frequency signal overwritten on the original image between the lines of the reproduced image and the original image which are corresponding to each other, thereby to detect at least one of the line shift and the frame shift; and subjecting the reproduced image to a narrow-band band-pass filtering to extract the signal-frequency signal, and calculating the inner product of a signal obtained by subjecting the signal-frequency signal to an offset processing and each inter-pixel interpolation of the signal-frequency signal overwritten on the original image between the lines of the reproduced image and the original image which are corresponding to each other, thereby to detect the horizontal pixel shift.
Furthermore, the present invention is an apparatus for detecting the synchronization shift between an original image and a reproduced image, characterized by comprising an overwriting means for overwriting a sine wave or a cosine wave on a plurality of predetermined lines of the original image, a narrow-band band-pass filter means for extracting only the sine wave or cosine wave with respect to the reproduced image on which the sine wave or cosine wave has been overwritten, an offset correction means for performing a direct-current offset correction on the sine or cosine wave having passed through the band-pass filter means, and a detecting means for detecting at least one of the line shift, frame shift and horizontal pixel shift by using the original image and the sine or cosine wave of the reproduced image on which the offset correction has been made.
In accordance with the present invention, since a signal of a substantially signal frequency is used as the synchronization marker for the original image and the reproduced image, noises of the various frequencies generated by the processing by a video codec or the like and superposed on the synchronization marker can be completely removed. Accordingly, the line shift, frame shift and horizontal pixel shift between the original image and the reproduced image can be accurately detected.